package com.gitee.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.gitee.bo.AdminBo;
import com.gitee.bo.AdminInfoBo;
import com.gitee.bo.AdminPasswordBo;
import com.gitee.pojo.Admin;
import com.gitee.vo.AdminVo;
import com.gitee.vo.PageVo;

public interface IAdminService extends IService<Admin> {

    /**
     * 查询后台用户
     * @param keywords
     * @param pageNum
     * @param pageSize
     * @return
     */
    PageVo<AdminVo> pageAdmin(String keywords, Integer pageNum, Integer pageSize);

    /**
     * 新增后台用户
     * @param adminBo
     * @return
     */
    Boolean addAdmin(AdminBo adminBo);

    /**
     * 更新后台用户
     * @param adminBo
     * @Param sysUserId
     * @return
     */
    Boolean updateAdmin(AdminBo adminBo, Integer adminId);

    /**
     * 后台用户自己更新信息
     * @param adminInfoBo
     * @param adminId
     * @return
     */
    Boolean updateAdminInfo(AdminInfoBo adminInfoBo, Integer adminId);

    /**
     * 后台用户自己修改密码
     * @param adminPasswordBo
     * @return
     */
    Boolean updateAdminPassword(AdminPasswordBo adminPasswordBo, Integer adminId);

    /**
     * 删除后台用户及其关联的角色
     * @param adminId
     * @return
     */
    Boolean deleteAdmin(Integer adminId);

    /**
     * 批量删除用户机器关联的角色
     * @param adminIds
     * @return
     */
    Boolean deleteAdminBatch(Integer[] adminIds);
}
